package com.configure.elasticsearch;

import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.boot.context.properties.NestedConfigurationProperty;
import org.springframework.stereotype.Component;

import java.util.ArrayList;
import java.util.List;


@Component
@ConfigurationProperties(prefix = "elasticsearch")
public class ElasticsearchProperty {

    @NestedConfigurationProperty
    private List<Host> hosts = new ArrayList<>();







    /**
     * Getter for property 'hosts'.
     *
     * @return Value for property 'hosts'.
     */
    public List<Host> getHosts() {
        return hosts;
    }

    /**
     * Setter for property 'hosts'.
     *
     * @param hosts Value to set for property 'hosts'.
     */
    public void setHosts(List<Host> hosts) {
        this.hosts = hosts;
    }




}
